<template>
  <div class="container-ghost">
    <div class="container-ghost__body" ref="body">
      <slot/>
    </div>
  </div>
</template>

<script>
import scroll from './mixins/normal'
export default {
  name: 'container-ghost',
  mixins: [
    scroll
  ],
  mounted () {
    // 增加滚动事件监听
    this.addScrollListener()
  },
  beforeDestroy () {
    // 移除滚动事件监听
    this.removeScrollListener()
  }
}
</script>
